﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ZLManage.aspx.cs" Inherits="Admin_ZLManage" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <link href="../../css/all.css" rel="stylesheet" type="text/css" />
        	<script type="text/javascript" src="../../js/jquery-1.10.2.min.js"></script>
    <script type="text/javascript" src="../../js/Utils.js"></script>
    <script language="javascript" type="text/javascript" src="../../js/date/WdatePicker.js"></script>
    <script type="text/javascript">
        function delItem() {
            var num = 0;
            for (var i = 0; i < document.form1.elements.length; i++) {
                if (document.form1.elements[i].checked) {
                    num++;
                }
                //else num=0;
            }
            if (num > 0) {
                var result = confirm("操作不可以恢复，确定当前操作吗？");
                if (result) {
                    return true;
                }
                else return false;

            }
            else {
                alert('你没选择任何内容！');
                return false;
            }
        }



        function SelectAll(box) {
            for (var i = 0; i < document.form1.elements.length; i++) {
                var e = document.form1.elements[i];
                if ((e.type == 'checkbox')) {
                    var o = e.name.lastIndexOf('cbx');
                    if (o != -1) {
                        e.checked = box.checked;
                    }
                }
            }
        }

        var iWidth = 640; //弹出窗口的宽度;
        var iHeight = 470; //弹出窗口的高度;
        var iTop = (window.screen.availHeight - 30 - iHeight) / 2; //获得窗口的垂直位置;
        var iLeft = (window.screen.availWidth - 10 - iWidth) / 2; //获得窗口的水平位置;

        function showUploadDialog() {
            var arr = showModalDialog("../../UserControl/MineName.aspx", window, "dialogWidth:" + iWidth + "px;dialogHeight:" + iHeight + "px;dialogTop:" + iTop + "px;dialogLeft:" + iLeft + "px;help:no;scroll:no;status:no");
        }

        function showUploadDialogt() {
            var arr = showModalDialog("../../UserControl/XZArea.aspx", window, "dialogWidth:" + iWidth + "px;dialogHeight:" + iHeight + "px;dialogTop:" + iTop + "px;dialogLeft:" + iLeft + "px;help:no;scroll:no;status:no");
        }

    </script>

    <style type="text/css">
        html,body
        {
            margin:0px;
        }
    </style>

</head>
<body onload="TableStyle()">
    <form id="form1" runat="server">
        <div id="TableContent" style="text-align: center; width: 100%; height: 100%;">

            <asp:Repeater ID="ZLRepeater" runat="server" OnItemCommand="ZLRepeater_ItemCommand">
                <HeaderTemplate>
                    <table style="height: 100%; width: 100%;" id="TheTable">
                        <tr>
                            <td colspan="10">
                                <table id="TheTable2" class="TheTable2" width="100%" border="0" align="left" cellpadding="0" cellspacing="0" style="margin: 0px; padding: 0px; text-align: left;" bgcolor="#E2FDFE">
                                    <tr>
                                        <td colspan="8" style="font-family: '微软雅黑'; font-size: 16px; background: rgba(0, 148, 255, 0.52)">项目信息筛选</td>
                                    </tr>
                                    <tr>
                                        <td>题 &nbsp;&nbsp;名</td>
                                        <td>
                                            <input type="text" name="TITLE" id="TITLE" />
                                        </td>
                                        <td>档 &nbsp;&nbsp;号</td>
                                        <td>
                                            <input type="text" name="FILE_ID" id="FILE_ID" /></td>

                                        <td height="35">关键词</td>
                                        <td>
                                            <input type="text" name="KEY_WORDS" id="KEY_WORDS" /></td>
                                        <td>形成单位</td>
                                        <td>
                                            <input type="text" name="UNIT" id="UNIT" /></td>
                                    </tr>
                                    <tr>
                                        <td>资料类别</td>
                                        <td>
                                            <select id="DATA_CLASS" name="DATA_CLASS">
                                                <option value="">----------</option>
                                                <option value="区调">区调</option>
                                                <option value="矿调">矿调</option>
                                            </select>
                                        </td>
                                        <td>工作程度</td>
                                        <td>
                                            <select id="WORK_LEVEL" name="WORK_LEVEL">
                                                <option value="">----------</option>
                                                <option value="1/100万">1/100万</option>
                                                <option value="1/50万">1/50万</option>
                                                <option value="1/25万">1/25万</option>
                                                <option value="1/20万">1/20万</option>
                                                <option value="1/10万">1/10万</option>
                                                <option value="1/5万">1/5万</option>
                                                <option value="其他比例尺">其他比例尺</option>
                                                <option value="预查">预查</option>
                                                <option value="普查">普查</option>
                                                <option value="详查">详查</option>
                                                <option value="勘探">勘探</option>
                                                <option value="开发勘探">开发勘探</option>
                                                <option value="钻井地质">钻井地质</option>
                                                <option value="其他">其他</option>
                                            </select>
                                        </td>

                                        <td>矿&nbsp;&nbsp;种</td>
                                        <td>
                                            <input type="text" name="MineType" id="MineType" />
                                            <img src="../../pic/kc.png" width="16" height="16" align="absmiddle" onclick="showUploadDialog()" style="cursor: pointer; vertical-align: bottom;" /></td>
                                        <td>行政区划</td>
                                        <td>
                                            <input type="text" name="XZArea" id="XZArea" /><img src="../../pic/kc.png" width="16" height="16" align="absmiddle" onclick="showUploadDialogt()" style="cursor: pointer; vertical-align: bottom;" /></td>



                                    </tr>
                                    <tr>
                                        <td>形成时间</td>
                                        <td colspan="3">

                                            <input type="text" id="START_DATE" name="START_DATE" onfocus="WdatePicker()" />
                                            <img src="../../img/calendar.gif" width="18" height="20" alt="开始时间" style="cursor: pointer" />
                                            &nbsp;到&nbsp;<input type="text" id="END_DATE" name="END_DATE" value="" onfocus="WdatePicker()" />
                                            <img src="../../img/calendar.gif" width="18" height="20" alt="结束时间" style="cursor: pointer" />
                                        </td>

                                        <td colspan="4">
                                            <asp:ImageButton src="../../pic/search.png" ID="SearchBtn" Height="25px" Width="60px" runat="server"
                                                OnClick="SearchBtn_Click" />

                                        </td>
                                    </tr>


                                </table>

                            </td>
                        </tr>
                        <tr>
                            <td colspan="7" class="thelistTitle">项目信息列表</td>
                            <td colspan="3" class="thelistTitle"><a href="../add/addProj.aspx">添加项目记录</a></td>
                        </tr>

                        <tr class="thelistTitle2">
                            <td>序号</td>
                            <td>档    号</td>
                            <td>项目名称</td>
                            <td>形成单位</td>
                            <td>馆藏机构</td>
                            <td>矿区名称</td>
                            <td>入库时间</td>
                            <td colspan="3">操作</td>
                        </tr>
                </HeaderTemplate>
                <ItemTemplate>
                    <tr>
                        <td width="3%">
                            <asp:Label ID="LBL" runat="server" Text='<%#Eval("ID")%>'></asp:Label></td>
                        <td width="7%"><%# Eval("FILE_ID")%> </td>
                        <td width="20%"><a target="_blank" href="../../GeoDataDetails.aspx?FID=<%# Eval("FILE_ID")%>"><%#Eval("PEOJ_NAME")%></a></td>
                        <td width="15%"><%#Eval("UNIT")%></td>
                        <td width="15%"><%#Eval("GC_DEPART")%></td>
                        <td width="15%"><%#Eval("MINE_NAME")%></td>
                        <td width="7%"><%#Eval("PUTIN_DATE")%></td>
                        <td width="4%">
                            <img alt="编辑" src="../../img/edit.gif" height="11" width="12" />
                            <asp:LinkButton ID="lnkEdit" PostBackUrl='<%# Eval("ID", "../Edit/ZLEdit.aspx?zlid={0}") %>' CommandName="EditData" runat="server">编辑</asp:LinkButton>

                        </td>
                        <td width="4%">
                            <img alt="删除" height="12" width="13" src="../../img/del.gif" />
                            <asp:LinkButton ID="lnkDelete" CommandName="DelData" CommandArgument='<%# Eval("ID") %>' OnClientClick="return confirm('确认要删除吗?请谨慎操作，删除后不可恢复。')" runat="server">删除</asp:LinkButton></td>
                        <td width="5%">
                            <asp:CheckBox ID="cbx" name="cbx" runat="server" /></td>
                    </tr>
                </ItemTemplate>
                <%--<AlternatingItemTemplate>
                    <tr style="background-color: #f0f5f8">
                        <td><asp:Label ID="LBL" runat="server" Text='<%#Eval("ID")%>' ></asp:Label></td>
                        <td><%# Eval("FILE_ID")%></td>
                        <td  ><%#Eval("PEOJ_NAME")%></td>
                        <td  ><%#Eval("UNIT")%></td>
                        <td  ><%#Eval("GC_DEPART")%></td>
                        <td  ><%#Eval("MINE_NAME")%></td>
                        <td  ><%#Eval("PUTIN_DATE")%></td>
                          <td>
                            <img alt="编辑" src="../../img/edit.gif" height="11" width="12" />
                            <asp:LinkButton ID="lnkEdit" CommandName="EditData"  PostBackUrl='<%# Eval("ID", "../Edit/ZLEdit.aspx?zlid={0}") %>' runat="server">编辑</asp:LinkButton>
                             
                          </td>
                        <td>
                            <img alt="删除" height="12" width="13" src="../../img/del.gif" />
                            <asp:LinkButton ID="lnkDelete" CommandName="DelData" CommandArgument='<%# Eval("ID") %>' OnClientClick="return confirm('确认要删除吗?请谨慎操作，删除后不可恢复。')"  runat="server">删除</asp:LinkButton></td>
                        <td>
                            <asp:CheckBox  ID="cbx" name="cbx" runat="server" /></td>
                    </tr>
                </AlternatingItemTemplate>--%>
                <FooterTemplate>
                    <tr runat="server">

                        <td colspan="7"></td>

                        <td colspan="2">
                            <asp:Button ID="btnDel" runat="server" OnClick="btnDel_Click" Text="批量删除" OnClientClick="return delItem()" Style="text-align: center;" /></td>
                        <td>
                            <asp:CheckBox ID="chkAll" onclick="SelectAll(this)" runat="server"
                                Text="全选" /></td>
                    </tr>
                    </table>
                </FooterTemplate>
            </asp:Repeater>
            <webdiyer:AspNetPager ID="AspNetPager1" Width="100%" CssClass="paginator" runat="server" ShowPageIndex="true" ShowPageIndexBox="always" AlwaysShow="True"
                PageIndexBoxType="TextBox" TextBeforePageIndexBox="翻页" OnPageChanging="AspNetPager1_PageChanging" PageSize="10" ShowBoxThreshold="1" CurrentPageButtonClass="cpb" HorizontalAlign="center" ShowCustomInfoSection="left" CustomInfoHTML="页次:%CurrentPageIndex%/%PageCount%页      每页:%PageSize%条    共:%RecordCount%条记录">
            </webdiyer:AspNetPager>
        </div>


    </form>
</body>
</html>
